import java.math.BigDecimal;
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);

        while (scanner.hasNext()) {

            String num1Str = scanner.next();
            String num2Str = scanner.next();


            BigDecimal num1 = new BigDecimal(num1Str);
            BigDecimal num2 = new BigDecimal(num2Str);


            BigDecimal sum = num1.add(num2);
            // 计算积
            BigDecimal product = num1.multiply(num2);


            System.out.println(sum.toString());
            System.out.println(product.toString());
        }

        scanner.close();
    }
}
